package site.jjqzplucky.user.domain.dto;

import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Pattern;
import lombok.Data;

@Data
public class UserDto {

    private Long id;

    @NotBlank(message = "用户名不能为空")
    @Pattern(regexp = "^[a-zA-Z0-9]{4,10}$", message = "用户名格式不正确")
    private String username;

    @NotBlank(message = "用户名不能为空")
    @Pattern(regexp = "^[a-zA-Z0-9]{6,20}$", message = "密码格式不正确")
    private String password;

    @NotBlank(message = "名字不能为空")
    private String name;

    @NotBlank(message = "性别不能为空")
    private Integer sex;

    @NotBlank(message = "手机号不能为空")
    private String tel;
    private String email;
    private Long deptId;
    private String job;
    private Long refId;
    private Integer status;
}
